home *** CD-ROM | disk | FTP | other *** search
- /*
- GetTLE - MemoDebug.h - Declarations of debug routines
- Copyright ⌐2000 Andreas Schneider
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
- #ifndef MemoDebugIncluded
- #define MemoDebugIncluded
-
- // if DEBUGGING is #define'd calls to LogXXX()
- // will write their output to a Memo under PalmOS and
- // to a file under Linux. If its not #defined they will
- // have no effect.
-
- #ifdef linux
- #include <stdarg.h>
- #else
- #include <unix_stdarg.h>
- #endif
-
- #define DEBUGGING
-
- // Prototypes for functions implemented in MemoDebug.c
- // Because of the varargs I'll implement 2 versions of LogMessage
- extern void LogMessage(char *format,...);
- // also implement a v-variant of that function
- extern void VLogMessage(char *format,va_list args);
-
- // for the two others I get away with empty macros if we don't use them
-
- #ifdef DEBUGGING
-
- extern void InitDebugMessages(void);
- extern void StartDebugMessages(void);
- extern void StopDebugMessages(void);
- extern void WriteDebugMessages(void);
-
- #else
-
- #define InitDebugMessages()
- #define StartDebugMessages()
- #define StopDebugMessages()
- #define WriteDebugMessages()
-
- #endif
-
- #endif
-